package com.mimi.exception;

import com.mimi.enums.ResultEnum;
import lombok.Getter;

/**
 * @Author:徐向
 * @Description:异常
 * @Date: Created in 13:13 2017/10/9
 */
@Getter
public class SellException extends  RuntimeException{

    private  Integer code;

    public SellException(ResultEnum resultEnum) {
       super(resultEnum.getMessage());
       this.code =resultEnum.getCode();
    }

    public SellException(Integer code,String message) {
        super(message);
        this.code=code;
    }
}
